//
//  M4VersionAlertView.swift
//  M4
//
//  Created by YuChuang on 2024/8/22.
//

import UIKit

class M4VersionAlertView: UIView {
    
    @IBOutlet weak var M4VersionUpdateButton: UIButton!
    
    @IBOutlet weak var M4VersionCloseButton: UIButton!
    
    @IBOutlet weak var M4VersionCloseTop: NSLayoutConstraint!
    
    @IBOutlet weak var M4VersionCloseHeight: NSLayoutConstraint!
    
    
    @IBOutlet weak var M4VersionContentLabel: UILabel!
    
    var M4VersionUpdateBlock: (() -> Void)?

    override func awakeFromNib() {
        self.frame = CGRect(x: 0, y: 0, width: M4ScreenWidth, height: M4ScreenHeight)
    }
    
    @IBAction func M4VersionUpdateAction(_ sender: UIButton) {
        self.M4AlertViewHidden()
        M4VersionUpdateBlock?()
        sender.M4EventUnavailable = false
    }
    
    @IBAction func M4VersionCloseAction(_ sender: UIButton) {
        self.M4AlertViewHidden()
        sender.M4EventUnavailable = false
    }
    
}
